// simpleDefault布局 计算表格高度
export const recalculateTableHeight = {
  mounted () {
    this.recalculateTableHeight()
  },
  methods: {
    recalculateTableHeight () { // 重新计算表格高度
      this.$nextTick(() => {
        var condationHeight = this.$refs.condationHeight.offsetHeight // 条件高度
        var tabHeight = this.$refs.tabHeight.offsetHeight // 表格高度
        var paginationHeight = this.$refs.paginationHeight.offsetHeight // 分页高度
        var clientHeight = document.body.clientHeight // 屏幕高度
        setTimeout(() => {
          this.tableHeight = clientHeight - condationHeight - tabHeight - paginationHeight - 50 - 120
        }, 0)
      })
    }
  }
}
